// 文章相关的请求模块


import request from '@/utils/request'
// 获取文章列表
export const getArticleList = ({current, pageSize}) => {
    return request.get('/admin/interview/query', {
        params: {
            current,
            pageSize,
        }
    })
}

//添加文章
export const createArticle = data => {
    return request.post('/admin/interview/create', data)
}

//删除文章
export const removeArticle = id => {
    return request.delete('/admin/interview/remove', {
        data: {
            id
        }
    })
}

// 获取单个面经详情
export const getArticleDetail = id => {
    return request.get('/admin/interview/show', {
        params: {
            id
        }
    })
}

//更新面经数据
export const updateArticle = data => {
    return request.put('/admin/interview/update', data)
}